package com.boot.springboot.entity;


import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.Id;
import java.io.Serializable;


/**
 * @author
 * @create 2018-07-17 17:22
 **/
@Entity
public class User  implements Serializable{

    private static final long serialVersionUID = 1L;

    @Id
    @Column(name = "USER_ID")
    private  String userId;

    @Column(name = "NAME",nullable = false,length = 5)
    private String name;

    @Column(name = "AGE")
    private  Integer age;

    public User() {
    }

    public User(String userId, String name, Integer age) {
        this.userId = userId;
        this.name = name;
        this.age = age;
    }

    public String getUserId() {
        return userId;
    }

    public void setUserId(String userId) {
        this.userId = userId;
    }

    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }

    public Integer getAge() {
        return age;
    }

    public void setAge(Integer age) {
        this.age = age;
    }
}
